import  axios from "../../axios.js"

//角色权限菜单接口
export default{
  // 获取返佣数据
  GETALL_RETURN(data)
  {
    return axios({
      url:'/frontBackPay/listChannelCommission',
      method:'post',
      data
    })
  },

  // 获取渠道认领单
  GET_CHANNALORDERS(data)
  {
    return axios({
      url:'/ChannelCommissionClaim/list',
      method:'post',
      data
    })
  },
  
  // 渠道认领单新增
  INSERT(data)
  {
    return axios({
      url:'/ChannelCommissionClaim/insert',
      method:'post',
      data
    })
  },
  
   // 渠道认领单修改
  UPDATE(data)
  {
    return axios({
      url:'/ChannelCommissionClaim/update',
      method:'post',
      data
    })
  },
  
   // 渠道认领单删除
  DELETE(data)
  {
    return axios({
      url:'/ChannelCommissionClaim/delete',
      method:'post',
      data
    })
  },

     // 充公
     confiscate(data)
     {
       return axios({
         url:'/ChannelCommissionClaim/confiscate',
         method:'get',
         params:data
       })
     },
   

   //认领明细
   ORDERS(data)
   {
     return axios({
       url:'/ChannelCommissionClaim/selectCommission',
       method:'get',
       params:data
     })
   },

   ORDERSDetails(data)
   {
     return axios({
       url:'/ChannelCommissionClaim/selectCommissionAll',
       method:'get',
       params:data
     })
   },

   // 认领数据保存接口
   SAVE(data)
   {
     return axios({
       url:'/ChannelCommissionClaim/insertCommissionClaim',
       method:'post',
       data
     })
   },

      // 出纳确认认领单修改返佣状态
   SAVE_TYPE(data)
      {
        return axios({
          url:'/ChannelCommissionClaim/updateCommissionStatus',
          method:'post',
          data
        })
      },
    
    //导出
    excelExport(data,fileName) {
      return axios({
        url:'/ChannelCommissionClaim/export?fileName=' + fileName,
        method:'get',
        params:data
      })
    },

    //导入
    importData(data) {
      return axios({
        url:'/ChannelCommissionClaim/import',
        method:'post',
        data
      })
    },

    //获取后台中心
    gethouTaiCenter(data) {
      return axios({
        url:'/crm/selectAllBackDepart',
        method:'get',
        params:data
      })
    },

    selectFrontAndEndCenter(data){
      return axios({
        url:'/crm/selectFrontAndEndCenter',
        method:'get',
        params:data,
      })
    },

     //获取前台数据
     getselectFrontUser(data) {
      return axios({
        url:'/crm/selectFrontUser',
        method:'get',
        params:data
      })
    },

     //获取前台数据
     getselectBackUser(data) {
      return axios({
        url:'/crm/selectBackUser',
        method:'get',
        params:data
      })
    },

  // 查看所有未停用的渠道
  selectChannel(data) {
    return axios({
      url: '/channelMaintenance/all',
      method: 'get',
      params:data
    })
  },

   // 查看打印信息
   printCommissionClaim(data) {
    return axios({
      url: 'ChannelCommissionClaim/printCommissionClaim',
      method: 'get',
      params:data
    })
  },
};
